package com.bwie.interrogation.controller;

import com.bwie.common.core.domain.Result;
import com.bwie.interrogation.domain.dto.AddReviewDTO;
import com.bwie.interrogation.service.MedPatientEvaluateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("patientEvaluate")

public class EvaluateController {
    /**
     * 注入
     */
    @Autowired
    private MedPatientEvaluateService service;

    /**
     * 患者评论就诊
     * @return
     */
    @PostMapping("medAddReview")
    public Result medAddReview(@RequestBody AddReviewDTO addReviewDTO){
        addReviewDTO.setDoctorId(1L);
        //调用方法
        service.medAddReview(addReviewDTO);
        //返回
        return Result.success();
    }
}
